package cn.iocoder.yudao.module.data.controller.admin.ds.vo;

import cn.iocoder.yudao.framework.common.pojo.PageParam;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;

import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;

/**
 * @author gukun
 */
@Schema(description = "管理后台 - 分类分页 Request VO")
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
//CREATE TABLE `data_ds_table` (
//        `id` bigint NOT NULL COMMENT 'ID',
//        `name` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '名称',
//        `table_name` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '物理表名',
//        `datasource_id` bigint DEFAULT NULL COMMENT '数据源ID',
//        `dataset_group_id` bigint NOT NULL COMMENT '数据集ID',
//        `type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT 'db,sql,union,excel,api',
//        `info` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci COMMENT '表原始信息,表名,sql等',
//        `sql_variable_details` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci COMMENT 'SQL参数',
//        PRIMARY KEY (`id`)
//) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='table数据集';
public class DsPageReqVO extends PageParam {

    @Schema(description = "名称，模糊匹配", example = "mysql")
    private String name;

    @Schema(description = "描述，模糊匹配", example = "这是个数据库")
    private String description;

    @Schema(description = "数据源ID", example = "1")
    private Long dsId;

    @Schema(description = "数据集ID", example = "1")
    private Long datasetGroupId;

    @Schema(description = "类型", example = "db")
    private String type;

    @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
    @Schema(description = "创建时间")
    private LocalDateTime[] createTime;

}